<!DOCTYPE html>
<html lang="en">
{{template "head" .}}
<title>{{.Site.Title}} | {{.Title}}</title>
<body>
    <!--导航栏-->
    <header class="masthead" style="background-image: url('{{.Site.Root}}/bundle/home-bg.jpg')">
        <div class="overlay"></div>
        {{template "header" .}}
        <div class="container">
            <div class="row">
                <div class="col-md mx-auto">
                    <div class="site-heading">
                        <span>{{.Site.Subtitle}}</span>
                    </div>
                </div>
            </div>
        </div>
    </header>
    <!-- 页面头部 -->
    <div class="container">
        <div class="row">
            <div class="col-md mx-auto">
            <article class="article">
                <a class="title">{{.Title}}</a>
                <section class="info">
                    {{if .Author.Avatar}}<img class="logo"  style="background-image: url('{{.Author.Avatar}}');"></img>{{end}} 
                    {{if .Author.Name}}<a class="name" href="{{.Site.Root}}/about.{{.Author.Id}}.html">{{.Author.Name}}</a>{{end}}
                    {{if .Update}}
                    <span class="date">{{.PageUpdate}}</span>
                    {{else}}
                    <span class="date">{{.PageDate}}</span>
                    {{end}}
                    <span class="tags">{{range .Tags}}<a class="tag"
                            href="{{$.Site.Root}}/tag/{{.}}/index.html">{{.}}</a>{{end}}</span>
                </section>
                <section class="markdown-body">{{.Content}}</section>
                <section class="order">THE END</section>
                <!-- 评论区 --->
                <section>
                  <h4 >{{i18n "comment"}}</h4>
                    {{template "comment" .}}
                </section>
                <section class="author">
                    {{if .Author.Avatar}}<div class="avatar" style="background-image: url({{.Author.Avatar}});"></div>{{end}}
                    <a class="name" href="{{.Site.Root}}/about.{{.Author.Id}}.html">{{.Author.Name}}</a>
                    <div class="intro">{{.Author.Intro}}</div>
                </section>
                <section class="recommend">
                    {{if .Prev}}
                    <section class="prev{{if .Next}} more{{end}}">
                        <div class="head">{{i18n "prev_reading"}}</div>
                        <a class="link" href="{{.Site.Root}}/{{.Prev.Link}}">{{.Prev.Title}}</a>
                    </section>
                    {{end}}
                    {{if .Next}}
                    <section class="next{{if .Prev}} more{{end}}">
                        <div class="head">{{i18n "next_reading"}}</div>
                        <a class="link" href="{{.Site.Root}}/{{.Next.Link}}">{{.Next.Title}}</a>
                    </section>
                    {{end}}
                </section>
            </article>
            </article> 
            </div>
        </div>
    </div>
</body>
{{template "footer" .}}
</html>